Learning Flex Basics (Part 1): Creating Your First Flex Application
Table of Contents
- Introduction
- A Brief Overview of Macromedia Flex
- Building the Application
- Create the Application Object
- Add a Panel for the Application Layout
- Add a Label for the View Header
- Add an Array of Objects to Define the Coffee Blends
- Add a ComboBox to Display the Coffee Blends
- Add a Text Control to Display the Description
- Add a Button to Add a Coffee Blend to the Shopping Cart
- Add a List Control for the Shopping Cart
- Add a Script to Handle the Button Click Event
- Complete Code Listing for firstapp.mxml
- Where to Go From Here
Add a Label for the View Header
Use the Label element to display a single line of text. It has a number of properties; here you use the text attribute, which defines the text that will display in the Label
-
Inside the Panel block, add a Label with the attributes as shown below:
<mx:Label text="Coffee Blends"/>
- Save the file and browse the application.